#include "SceneManualState.h"
#include "Game.h"

SceneManualState::SceneManualState(void)
{
}


SceneManualState::~SceneManualState(void)
{
}

void SceneManualState::init()
{
	Game * game = Game::getInstance();
	SceneManualListener * lis = new SceneManualListener(game->mRoot,game->mCamera, 
		game->mSceneMgr,game->mWindow,game->mMouse,game->mKeyboard,game->mInputManager);
	frameListener = lis;
	keyListener = lis;
	MouseListener = lis;
	windowEventListener=lis;
}

void SceneManualState::stateStarted()
{
	Ogre::WindowEventUtilities::addWindowEventListener(Game::getInstance()->mWindow, this->windowEventListener);
	Game::getInstance()->mRoot->addFrameListener(this->frameListener);
	Game::getInstance()->mMouse->setEventCallback(this->MouseListener);
	Game::getInstance()->mKeyboard->setEventCallback(this->keyListener);
}

void SceneManualState::stateEnded()
{

}
